<template>
	<view class="content">
	
		
		
		
		<view class="panel_top">
			<view class="box_title">
				<view class="title_left">产品信息</view>
				<view class="title_right" ></view>
			</view>
		</view>
		
		<view class="panel_box">
			<view class="panel_box_title"></view>
			<view class="popup_form">
				
				
				<view class="product_list">
					<view v-for="(item,index) in formData.products" :key="index" class="product_item">
						<view class="product_title">
							<view class="product_title_left">{{item.cInvName}}</view>
							<view class="product_title_right">
								<uni-icons @click="delProduct(index)" type="closeempty" color="#9a9a9a" :size="icons[34]" />
							</view>
						</view>
						<view class="product_desc">产品型号：{{item.cInvCode}}</view>
						<view class="product_desc">产品规格：{{item.cInvStd}}</view>
						<view class="product_num">
		
							<view class="form_item_input">
								<input v-model="formData.products[index]['box_num']"  type="text" class="uni-input"  placeholder-style="color:#a9a9a9"  placeholder="箱数" />
							</view>
							
							<!--<view class="form_item_input">
								<input v-model="formData.products[index]['roll_num']"  type="text" class="uni-input"  placeholder-style="color:#a9a9a9"  placeholder="卷数" />
							</view>-->

							<view class="product_num_text">产品数量：</view>
						</view>
	
					</view>
				</view>
				<view style="margin:auto;margin-top: 30rpx; margin-bottom: 20rpx; width: 60%;">
					<button type="default" class="button"  size="mini" style="width:100%;background-color: #910a15;color: #fff; font-size: 30rpx;" @click="selectPro()">添加产品</button>				
				</view>

			</view>
		</view>
		

		<view class="panel_top">
			<view class="box_title">
				<view class="title_left">其他信息</view>
				<view class="title_right" ></view>
			</view>
		</view>
		
		<view class="panel_box">
			<view class="panel_box_title"></view>
			<view class="popup_form" >
				<u--form labelPosition="left" :model="formData" :rules="rules" ref="form">
					
					<!--<u-form-item label="姓名" prop="formData.name" borderBottom ref="name">
						<u--input v-model="formData.name" placeholder="请输入内容" border="surround"></u--input>
					</u-form-item>-->
		
					<u-form-item  prop="req_date" labelWidth="80" borderBottom   >
						<uni-datetime-picker v-model="formData.req_date" type="date"  :clear-icon="false" placeholder="请选要货日期" />
					</u-form-item>
					
					<u-form-item  prop="mark" labelWidth="80" borderBottom   >
						<u--textarea v-model="formData.mark" placeholder="请输入备注" count ></u--textarea>
					</u-form-item>
				</u--form>
			</view>
		</view>
		
		<view style="margin-top: 80rpx; margin-bottom: 80rpx; width: 90%; float: right;" >
			<button type="default" class="button" style="background-color: #910a15;color: #fff; font-size: 30rpx;" @click="submitForm()">提交申请</button>				
		</view>

		<selectProductPopup :show.sync="selectShow" :selectInfo.sync="product" ></selectProductPopup>
	</view>
</template>


<script>
	import selectProductPopup from '@/pages/regood/components/select-product-popup/select-product-popup.vue';
	import  parentPage from '@/common/parent-page.js';
	import {index} from './index.js';
	export default {mixins: [parentPage,index],components: {'selectProductPopup': selectProductPopup}}
</script>



<style>
	@import './index.css';
</style>
